<?xml version="1.0" encoding="UTF-8"?>
<gexf xmlns="http://www.gexf.net/1.2draft" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.gexf.net/1.2draft http://www.gexf.net/1.2draft/gexf.xsd" version="1.2">
    <meta lastmodifieddate="2009-03-20">
        <creator>intrigue.io</creator>
        <description>generated graph</description>
    </meta>
    <graph defaultedgetype="undirected">
        <attributes class="node">
            <attribute id="0" title="name" type="string"/>
            <attribute id="1" title="type" type="string"/>
        </attributes>
        <nodes>
        <% @entity_pairs.each do |hash| %>
            <node id="<%= hash[:entity].id %>" label="<%= hash[:entity].name %>">
              <attvalues>
                <attvalue for="0" value="<%= hash[:entity].name %>"/>
                <attvalue for="1" value="<%= hash[:entity].type %>"/>
              </attvalues>
            </node>
        <% end %>
        </nodes>
        <edges>
          <% count=0 %>
          <% @entity_pairs.each do |hash| %>
              <edge id="<%="#{count}"%>" source="<%="#{hash[:task_result].base_entity.id}"%>" target="<%="#{hash[:entity].id}"%>" label="<%=hash[:task_result].name%>"/>
        <% count+=1
          end
          %>
        </edges>
    </graph>
</gexf>
